//
//  IDSTViewController.m
//  Screen Touches
//
//  Created by iD Student on 7/11/13.
//  Copyright (c) 2013 iD Student. All rights reserved.
//

#import "IDSTViewController.h"

@interface IDSTViewController ()

@end

@implementation IDSTViewController

- (void)viewDidLoad
{
    [super viewDidLoad];
	// Do any additional setup after loading the view, typically from a nib.
}

- (void) touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event
{
    UITouch *touch = [touches anyObject];
    CGPoint touchPoint = [touch locationInView:[self view]];
    NSLog(@"%d, %d", (int)touchPoint.x, (int)touchPoint.y);
}

- (void) touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event
{
    UITouch *touch2 = [touches anyObject];
    CGPoint touchPoint2 = [touch2 locationInView:[self view]];
    NSLog(@"%d, %d", (int)touchPoint2.x, (int)touchPoint2.y);
}

- (void) touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event
{
    UITouch *touch3 = [touches anyObject];
    CGPoint currentTouchPoint = [touch3 locationInView:[self view]];
    CGPoint previousTouchPoint = [touch3 previousLocationInView:[self view]];
    NSLog(@"%d, %d", (int)previousTouchPoint.x, (int)previousTouchPoint.y);
    NSLog(@"%d, %d", (int)currentTouchPoint.x, (int)currentTouchPoint.y);
}


- (void)didReceiveMemoryWarning
{
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

@end
